package org.xx.armory.spring5.autoconfigure;

import org.springframework.boot.autoconfigure.AutoConfigureOrder;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.Ordered;
import org.xx.armory.spring5.mvc.TaskLogConfig;

@Configuration
@ConditionalOnWebApplication
@AutoConfigureOrder(Ordered.HIGHEST_PRECEDENCE)
public class ArmoryTaskLogAutoConfiguration {
    @Bean
    @ConditionalOnMissingBean
    public TaskLogConfig taskLogConfigurer() {
        return new TaskLogConfig();
    }
}
